package com.jason.www.http.response;

import com.google.gson.annotations.SerializedName;

/**
 * @author：Jason
 * @date：2022/3/18 15:15
 * @email：1129847330@qq.com
 * @description:
 */
public class IdCardOCREntity {

    @SerializedName("log_id")
    public Long logId;
    @SerializedName("direction")
    public Integer direction;
    @SerializedName("image_status")
    public String imageStatus;
    @SerializedName("photo")
    public String photo;
    @SerializedName("photo_location")
    public PhotoLocationDTO photoLocation;
    @SerializedName("card_image")
    public String cardImage;
    @SerializedName("card_location")
    public CardLocationDTO cardLocation;
    @SerializedName("words_result")
    public WordsResultDTO wordsResult;
    @SerializedName("words_result_num")
    public Integer wordsResultNum;

    @Override
    public String toString() {
        return "IdCardOCREntity{" +
                "logId=" + logId +
                ", direction=" + direction +
                ", imageStatus='" + imageStatus + '\'' +
                ", photo='" + photo + '\'' +
                ", photoLocation=" + photoLocation +
                ", cardImage='" + cardImage + '\'' +
                ", cardLocation=" + cardLocation +
                ", wordsResult=" + wordsResult +
                ", wordsResultNum=" + wordsResultNum +
                '}';
    }

    public static class PhotoLocationDTO {
        @SerializedName("width")
        public Integer width;
        @SerializedName("top")
        public Integer top;
        @SerializedName("left")
        public Integer left;
        @SerializedName("height")
        public Integer height;

        @Override
        public String toString() {
            return "PhotoLocationDTO{" +
                    "width=" + width +
                    ", top=" + top +
                    ", left=" + left +
                    ", height=" + height +
                    '}';
        }
    }

    public static class CardLocationDTO {
        @SerializedName("top")
        public Integer top;
        @SerializedName("left")
        public Integer left;
        @SerializedName("width")
        public Integer width;
        @SerializedName("height")
        public Integer height;

        @Override
        public String toString() {
            return "CardLocationDTO{" +
                    "top=" + top +
                    ", left=" + left +
                    ", width=" + width +
                    ", height=" + height +
                    '}';
        }
    }

    public static class WordsResultDTO {
        @SerializedName("住址")
        public Address address;
        @SerializedName("公民身份号码")
        public IDNumber idNumber;
        @SerializedName("出生")
        public Birth birth;
        @SerializedName("姓名")
        public Name name;
        @SerializedName("性别")
        public Sex sex;
        @SerializedName("民族")
        public Nation nation;

        @Override
        public String toString() {
            return "WordsResultDTO{" +
                    "adress=" + address +
                    ", idNumber=" + idNumber +
                    ", birth=" + birth +
                    ", name=" + name +
                    ", sex=" + sex +
                    ", nation=" + nation +
                    '}';
        }

        public static class Address {
            @SerializedName("location")
            public LocationDTO location;
            @SerializedName("words")
            public String words;

            @Override
            public String toString() {
                return "Address{" +
                        "location=" + location +
                        ", words='" + words + '\'' +
                        '}';
            }

            public static class LocationDTO {
                @SerializedName("left")
                public Integer left;
                @SerializedName("top")
                public Integer top;
                @SerializedName("width")
                public Integer width;
                @SerializedName("height")
                public Integer height;

                @Override
                public String toString() {
                    return "LocationDTO{" +
                            "left=" + left +
                            ", top=" + top +
                            ", width=" + width +
                            ", height=" + height +
                            '}';
                }
            }

        }

        public static class IDNumber {
            @SerializedName("location")
            public LocationDTO location;
            @SerializedName("words")
            public String words;

            @Override
            public String toString() {
                return "IDNumber{" +
                        "location=" + location +
                        ", words='" + words + '\'' +
                        '}';
            }

            public static class LocationDTO {
                @SerializedName("left")
                public Integer left;
                @SerializedName("top")
                public Integer top;
                @SerializedName("width")
                public Integer width;
                @SerializedName("height")
                public Integer height;

                @Override
                public String toString() {
                    return "LocationDTO{" +
                            "left=" + left +
                            ", top=" + top +
                            ", width=" + width +
                            ", height=" + height +
                            '}';
                }
            }
        }

        public static class Birth {
            @SerializedName("location")
            public LocationDTO location;
            @SerializedName("words")
            public String words;

            @Override
            public String toString() {
                return "Birth{" +
                        "location=" + location +
                        ", words='" + words + '\'' +
                        '}';
            }

            public static class LocationDTO {
                @SerializedName("left")
                public Integer left;
                @SerializedName("top")
                public Integer top;
                @SerializedName("width")
                public Integer width;
                @SerializedName("height")
                public Integer height;

                @Override
                public String toString() {
                    return "LocationDTO{" +
                            "left=" + left +
                            ", top=" + top +
                            ", width=" + width +
                            ", height=" + height +
                            '}';
                }
            }
        }

        public static class Name {
            @SerializedName("location")
            public LocationDTO location;
            @SerializedName("words")
            public String words;

            @Override
            public String toString() {
                return "Name{" +
                        "location=" + location +
                        ", words='" + words + '\'' +
                        '}';
            }

            public static class LocationDTO {
                @SerializedName("left")
                public Integer left;
                @SerializedName("top")
                public Integer top;
                @SerializedName("width")
                public Integer width;
                @SerializedName("height")
                public Integer height;

                @Override
                public String toString() {
                    return "LocationDTO{" +
                            "left=" + left +
                            ", top=" + top +
                            ", width=" + width +
                            ", height=" + height +
                            '}';
                }
            }
        }

        public static class Sex {
            @SerializedName("location")
            public LocationDTO location;
            @SerializedName("words")
            public String words;

            @Override
            public String toString() {
                return "Sex{" +
                        "location=" + location +
                        ", words='" + words + '\'' +
                        '}';
            }

            public static class LocationDTO {
                @SerializedName("left")
                public Integer left;
                @SerializedName("top")
                public Integer top;
                @SerializedName("width")
                public Integer width;
                @SerializedName("height")
                public Integer height;

                @Override
                public String toString() {
                    return "LocationDTO{" +
                            "left=" + left +
                            ", top=" + top +
                            ", width=" + width +
                            ", height=" + height +
                            '}';
                }
            }
        }

        public static class Nation {
            @SerializedName("location")
            public LocationDTO location;
            @SerializedName("words")
            public String words;

            @Override
            public String toString() {
                return "Nation{" +
                        "location=" + location +
                        ", words='" + words + '\'' +
                        '}';
            }

            public static class LocationDTO {
                @SerializedName("left")
                public Integer left;
                @SerializedName("top")
                public Integer top;
                @SerializedName("width")
                public Integer width;
                @SerializedName("height")
                public Integer height;

                @Override
                public String toString() {
                    return "LocationDTO{" +
                            "left=" + left +
                            ", top=" + top +
                            ", width=" + width +
                            ", height=" + height +
                            '}';
                }
            }
        }
    }
}